<% content_for :head do  %>
  <%= stylesheet_link_tag 'products'%>
<% end %>
<%= stylesheet_link_tag 'products'%>
<div id="block-lists" class="block">
  <div class="secondary-navigation">
    <ul>
      <li class="first <%= params[:keywords].blank? ? 'active' : '' %>"><a href="#block-tables">热门翡翠商品搜索</a></li>
      <% Basetable.product_hotword.first.content.split(' ').each do |k| %>
        <li  class="<%= k == params[:keywords] ? 'active' : '' %>"><a href="/products?keywords=<%=to_seo(k)%>"><%= k %></a></li>
      <% end %>
    </ul>
    <div class="clear">   </div>
  </div>
  <div class="content">
    <h2 class="title">商品搜索</h2>
    <%= render :partial => "/products/search" , :locals=>{:url =>products_path} %>
    <div class="inner">
      <ul class="list">
        <% @products.each do |product| %>
          <li>
            <div class="left">
          <p style="clear: both;height:22px;margin:0">&nbsp; </p>
              <%= link_to image_tag(product.first_list_image) , product_path(product.id.to_s + '-'+ to_seo(product.name))%>
            </div>
            <div class="right"  >
              <p>&nbsp; </p>
              <p><%= link_to '详情' , product_path(product.id.to_s + '-'+ product.name)%></p>
            </div>
            <div class="middle">
              <p>种类：<%= product.sort.name %></p>
              <p>颜色：<%= product.color.name %></p>
              <p>价格: <%= product.price %></p>
              <p>编号：<%= product.serial %>  证书编号：<%= product.proved_serial %>  商户：<%= product.user.name %></p>
            </div>
          
            <p style="clear: both;"> </p>
          </li>
        <%end%>
                                                            
      </ul>
      <br/><br/>
      <%=  will_paginate @products%>         
      <br/>
    </div>
  </div>                               
</div>    
